package qnb.entity;

import java.util.ArrayList;
import java.util.List;

/**
 * 管理员后台权限表实体类
 *
 * @author
 */
public class SysPower {
    private Integer sysPowerId;        //自增id
    private Integer sysPowerPid;        //管理员权限id
    private String sysPowerName;        //管理员权限名称
    private String sysPowerCode;        //1=查询；2表示删除
    private String sysPowerUrl;        //权限关联的路径 还是 虚拟路径0
    private Boolean sysPowerStyle;        //权限状态
    private String sysPowerType; //0不在菜单显示,1显示
    private Integer sysPowerLevel;//权限等级 0可以给学生赋,1不行



    public String getSysPowerType() {
        return sysPowerType;
    }

    public void setSysPowerType(String sysPowerType) {
        this.sysPowerType = sysPowerType;
    }

    public Integer getSysPowerLevel() {
        return sysPowerLevel;
    }

    public void setSysPowerLevel(Integer sysPowerLevel) {
        this.sysPowerLevel = sysPowerLevel;
    }

    public static final String IS_MENU = "1";
    public static final String NOT_MENU = "0";

    @Override
    public String toString() {
        return "SysPower{" +
                "sysPowerId=" + sysPowerId +
                ", sysPowerPid=" + sysPowerPid +
                ", sysPowerName='" + sysPowerName + '\'' +
                ", sysPowerCode=" + sysPowerCode +
                ", sysPowerUrl='" + sysPowerUrl + '\'' +
                ", sysPowerStyle=" + sysPowerStyle +
                ", children=" + children +
                '}';
    }

    public String getSysPowerCode() {
        return sysPowerCode;
    }

    public void setSysPowerCode(String sysPowerCode) {
        this.sysPowerCode = sysPowerCode;
    }

    public SysPower() {
    }

    public SysPower(Integer sysPowerId, Integer sysPowerPid, String sysPowerName, String sysPowerCode, String sysPowerUrl, Boolean sysPowerStyle, List<SysPower> children) {
        this.sysPowerId = sysPowerId;
        this.sysPowerPid = sysPowerPid;
        this.sysPowerName = sysPowerName;
        this.sysPowerCode = sysPowerCode;
        this.sysPowerUrl = sysPowerUrl;
        this.sysPowerStyle = sysPowerStyle;
        this.children = children;
    }

    private List<SysPower> children;

    public List<SysPower> getChildren() {
        return children != null ? children : new ArrayList<>();
    }

    public void setChildren(List<SysPower> children) {
        this.children = children;
    }

    public Integer getSysPowerId() {
        return sysPowerId;
    }

    public void setSysPowerId(Integer sysPowerId) {
        this.sysPowerId = sysPowerId;
    }

    public Integer getSysPowerPid() {
        return sysPowerPid;
    }

    public void setSysPowerPid(Integer sysPowerPid) {
        this.sysPowerPid = sysPowerPid;
    }

    public String getSysPowerName() {
        return sysPowerName;
    }

    public void setSysPowerName(String sysPowerName) {
        this.sysPowerName = sysPowerName;
    }


    public String getSysPowerUrl() {
        return sysPowerUrl;
    }

    public void setSysPowerUrl(String sysPowerUrl) {
        this.sysPowerUrl = sysPowerUrl;
    }

    public Boolean getSysPowerStyle() {
        return sysPowerStyle;
    }

    public void setSysPowerStyle(Boolean sysPowerStyle) {
        this.sysPowerStyle = sysPowerStyle;
    }
}
